package com.jike.jkgame.network.data;

import com.jike.jkgame.data.ResourceType;
import com.jike.jkgame.data.UserResource;

public class LineupCastResultData {
	public int opcode;
	public Cast[] cast;

	public int army_att_min;
	public int army_att_max;
	public int army_def_min;
	public int army_def_max;

	public static class Cast {
		public int idx;
		public UserResource general;
		public UserResource weapon;
		public UserResource armor;
		public UserResource mount;
		public UserResource treasure;

		public void setResource(UserResource res) {
			if (res.res == ResourceType.General) {
				general = res;
			} else if (res.res == ResourceType.Weapon) {
				weapon = res;
			} else if (res.res == ResourceType.Armor) {
				armor = res;
			} else if (res.res == ResourceType.Mount) {
				mount = res;
			} else if (res.res == ResourceType.Treasure) {
				treasure = res;
			}
		}
	}
}
